<!--
  *@Description : In user setting edit
  *@author 萧红
  *@date 2020-04-26 16:37
  *@LastEditTime 2020-04-26 16:37
  *@LastEdititors
-->
<template>
    <div id="admin">
      <el-container :style="{height: $inerHeight+100+'px', border: '1px solid #eee',boxSizing:'border-box'}">
        <el-header>
          <div class="title">
            Cos社区管理员界面
          </div>
        </el-header>
        <el-container style="overflow: hidden">
          <el-aside width="200px" style="background-color: rgb(238, 241, 246)">
            <el-menu :default-openeds="['1']" default-active="1" class="el-menu-vertical-demo" @open="handleOpen" @close="handleClose" :collapse="false" @select="handleSelect">
              <el-submenu index="1">
                <template slot="title"><i class="el-icon-user"></i>用户管理</template>
                  <el-menu-item index="1">全部用户</el-menu-item>
                  <el-menu-item index="2">添加用户</el-menu-item>
                  <el-menu-item index="3">删除用户</el-menu-item>
                  <el-menu-item index="4">更新用户</el-menu-item>
              </el-submenu>
              <el-submenu index="2">
                <template slot="title"><i class="el-icon-goods"></i>商品管理</template>
                  <el-menu-item index="5">添加商品</el-menu-item>
                  <el-menu-item index="7">删除商品</el-menu-item>
                  <el-menu-item index="6">更新商品</el-menu-item>
              </el-submenu>
              <el-submenu index="3">
                <template slot="title"><i class="el-icon-s-order"></i>订单管理</template>
                  <el-menu-item index="8">全部订单</el-menu-item>
                  <el-menu-item index="9">代审核订单</el-menu-item>
              </el-submenu>
              <el-submenu index="4">
                <template slot="title"><i class="el-icon-s-help"></i>动态管理</template>
                  <el-menu-item index="10">删除动态</el-menu-item>
                  <el-menu-item index="11">举报查看</el-menu-item>
              </el-submenu>
              <el-submenu index="5">
                <template slot="title"><i class="el-icon-first-aid-kit"></i>权限管理</template>
                <el-menu-item-group>
                  <el-menu-item index="12">全部权限</el-menu-item>
                  <el-menu-item index="13">增加权限</el-menu-item>
                  <el-menu-item index="14">删除权限</el-menu-item>
                  <el-menu-item index="15">赋予权限</el-menu-item>
                </el-menu-item-group>
              </el-submenu>
              <el-submenu index="6">
                <template slot="title"><i class="el-icon-setting"></i>系统管理</template>
                <el-menu-item-group>
                  <el-menu-item index="16">已开启功能</el-menu-item>
                  <el-menu-item index="17">功能管理</el-menu-item>
                  <el-menu-item index="18">首屏</el-menu-item>
                  <el-menu-item index="19">第二屏</el-menu-item>
                </el-menu-item-group>
              </el-submenu>
            </el-menu>
            <!--<el-menu default-active="1-4-1" class="el-menu-vertical-demo" @open="handleOpen" @close="handleClose" :collapse="false">-->
              <!--<el-submenu index="1">-->
                <!--<template slot="title">-->
                  <!--<i class="el-icon-location"></i>-->
                  <!--<span slot="title">导航一</span>-->
                <!--</template>-->
                <!--<el-menu-item-group>-->
                  <!--<span slot="title">分组一</span>-->
                  <!--<el-menu-item index="1-1">选项1</el-menu-item>-->
                  <!--<el-menu-item index="1-2">选项2</el-menu-item>-->
                <!--</el-menu-item-group>-->
                <!--<el-menu-item-group title="分组2">-->
                  <!--<el-menu-item index="1-3">选项3</el-menu-item>-->
                <!--</el-menu-item-group>-->
                <!--<el-submenu index="1-4">-->
                  <!--<span slot="title">选项4</span>-->
                  <!--<el-menu-item index="1-4-1">选项1</el-menu-item>-->
                <!--</el-submenu>-->
              <!--</el-submenu>-->
              <!--<el-menu-item index="2">-->
                <!--<i class="el-icon-menu"></i>-->
                <!--<span slot="title">导航二</span>-->
              <!--</el-menu-item>-->
              <!--<el-menu-item index="3" disabled>-->
                <!--<i class="el-icon-document"></i>-->
                <!--<span slot="title">导航三</span>-->
              <!--</el-menu-item>-->
              <!--<el-menu-item index="4">-->
                <!--<i class="el-icon-setting"></i>-->
                <!--<span slot="title">导航四</span>-->
              <!--</el-menu-item>-->
            <!--</el-menu>-->
          </el-aside>
          <el-main>
            <router-view></router-view>
          </el-main>
        </el-container>
        <el-footer>
          版权所有&copy;2020 蓝色幻想工作室（谢红凯所有）
        </el-footer>
      </el-container>
    </div>
</template>

<script>
export default {
  name: 'admin',
  data () {
    return {
      isCollapse: true
    }
  },
  methods: {
    handleOpen (key, keyPath) {
      console.log(key, keyPath)
    },
    handleClose (key, keyPath) {
      console.log(key, keyPath)
    },
    handleSelect (key, keyPath) {
      console.log(key, keyPath)
    }
  }
}
</script>

<style scoped lang="stylus">
#admin
{
  box-sizing border-box
  font-family: "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;
  .el-header
  {
    width: 100%
    line-height 60px
    color:snow
    background-color deeppink
    .title{width:100%;}
  }
  .el-footer
  {
    background-color #ff689b
    line-height 60px
    color snow
    font-weight bolder
  }
}
.el-menu-vertical-demo:not(.el-menu--collapse) {
  width: 200px;
  min-height: 400px;
}
</style>
